package com.thunbu.thunbu_meeting_system.bean

import com.thunbu.thunbu_meeting_system.view.treeView.NodeModel
import java.io.Serializable
//{
//    "id": 19727,//id
//    "oldId": "SC01",//国标编码旧id
//    "categoryCode": "SC01",//类别编码,自定义超类为NK开头，子类在父类基础上+2位数,原始类别上添加为YS开头
//    "categoryName": "固定资产",//类别名称
//    "parentId": "",//父类别国标编码旧id
//    "parentCode": "",//父类别编码
//    "parentName": "",//父类别名称
//    "firstId": "",//大类别id,国标编码id，不一定等于层级为1的id
//    "firstName": "",//大类别国标名称
//    "tenantCode": "ZH211014100825Trw9SI",//租户编码
//    "level": 0,//资产分类层级
//    "businessId": 0,//行业
//    "categoryType": 0,//分类类型
//    "categoryHide": "0",//是否隐藏
//    "categoryDelete": "0",//是否删除
//    "categoryStandard": {},//关联国标分类
//    "categoryBusiness": {},//关联行业分类
//    "categoryDepreciation": null,//折旧方式
//    "categoryDepreciationStatus": null,//折旧状态
//    "categoryUsefulLife": null,//使用年限/月
//    "categoryUnit": null,//计量单位
//    "last": false,//是否为末级, 0 否; 1是
//    "custom": false,//0 同步资产云的类别; 1 自定义的类别
//    "templateId": null,//分类对应模板id
//    "childList": []//子节点列表
//}
data class AssetTypeModel(
    val id: Long?,
//    val oldId: String?,
    var categoryCode: String?,//资产分类编号
    var categoryName: String?,//资产分类名称
//    val parentId: String?,
//    val parentCode: String?,
//    val parentName: String?,
//    val firstId: String?,
//    val firstName: String?,
//    val tenantCode: String?,
//    val level: Int?,
//    val businessId: Int?,
//    val categoryType: Int?,
//    val categoryHide: String?,
//    val categoryDelete: String?,
//    val categoryStandard: CategoryStandard?,
//    val categoryBusiness: CategoryBusiness?,
//    val categoryDepreciation: Any?,
//    val categoryDepreciationStatus: Any?,
//    val categoryUsefulLife: Any?,
//    val categoryUnit: Any?,
//    val last: Boolean?,
//    val custom: Boolean?,
//    val templateId: Any?,
    val childList: List<AssetTypeModel>?
) :Serializable,NodeModel{
    override fun getmId(): Long {
        return id?:-1
    }

    override fun getName(): String? {
        return categoryName
    }

    override fun getCode(): String? {
        return categoryCode
    }

    override fun getChild(): List<AssetTypeModel>? {
        return childList
    }
//    class CategoryStandard(
//    )
//
//    class CategoryBusiness(
//    )
}